<?php

/**
* @copyright   (C) 2010 iJoomla, Inc. - All rights reserved.
* @license  GNU General Public License, version 2 (http://www.gnu.org/licenses/gpl-2.0.html) 
* @author  iJoomla.com webmaster@ijoomla.com
* @url   http://www.ijoomla.com/licensing/
* the PHP code portions are distributed under the GPL license. If not otherwise stated, all images, manuals, cascading style sheets, and included JavaScript  
* are NOT GPL, and are released under the IJOOMLA Proprietary Use License v1.0 
* More info at http://www.ijoomla.com/licensing/
*/

	defined( '_JEXEC' ) or die( 'Restricted access' );
	
	$title = "";
	$show_title = "1";
	$description = "";
	$ordering = "";
	$survey_id = "";
	
	if($this->values != ""){
		$title = $this->values["0"]["title"];
		$show_title = $this->values["0"]["show_title"];
		$description = $this->values["0"]["description"];
		$ordering = $this->values["0"]["ordering"];
		$survey_id = $this->values["0"]["survey_id"];
	}
?>

<div style="overflow:hidden">
	<table class="adminform" border="0" cellpadding="3" cellspacing="0" align="left">
		<tr>
			<td align="left" width="5%" nowrap="nowrap"><b><?php echo JText::_("COM_SURVEYS_PAGE_NAME"); ?>:</b><span style="color:#FF0000">*</span></td>
			<td align="left" >					
				<?php
					$title = str_replace('"', "&quot;", $title);
				?>
				<input class="inputbox" type="text" size="50" maxlength="250" name="title" value="<?php echo stripslashes($title) ; ?>" />
			</td>
		</tr>		
		<tr>
			<td align="left" width="5%" nowrap="nowrap"><b><?php echo JText::_("COM_SURVEYS_SURVEY_NAME"); ?>:</b> </td>
			<td align="left" >
				<?php echo $this->getSurveysList($survey_id); ?>
			</td>
		</tr>
		<tr>
			<td align="left" width="5%" nowrap="nowrap"><b><?php echo JText::_("COM_SURVEYS_SHOW_TITLE"); ?>:</b> </td>
			<td align="left" >
				<table>
					<tr>
						<td>
							<table>
								<tr>
									<td>
										<input type="radio" name="show_title" value="1" <?php if($show_title == "1"){echo 'checked="checked"';} ?> />
									</td>
									<td>	
										<?php echo JText::_("JYES"); ?>
									</td>
								</tr>
							</table>			
						</td>
						<td>
							<table>
								<tr>
									<td>
										<input type="radio" name="show_title" value="0" <?php if($show_title == "0"){echo 'checked="checked"';} ?> />
									</td>
									<td>	
										<?php echo JText::_("JNO"); ?>
									</td>
								</tr>
							</table>			
						</td>
					</tr>
				</table>			
			</td>
		</tr>
		<!-- <tr>
			<td align="left" width="5%" nowrap><b><?php //echo JText::_("COM_SURVEYS_ORDERING"); ?>:</b> </td>
			<td align="left" >
				<?php //echo $this->getOrdering($ordering); ?>
			</td>
		</tr> -->
		<tr>
			<td align="left" valign="top" nowrap><b><?php echo JText::_("COM_SURVEYS_DESCRIPTION"); ?>:</b></td>
			<td align="left" valign="top">
				<?php
					$editor1  =& JFactory::getEditor();
					echo $editor1->display( 'description',  ''.stripslashes($description) , '100%', '270px', '150', '10' ) ; 
				?>
			</td>
			
		</tr>
	</table>
</div>